﻿using InnoWeb.CEND.Core.Model.Base;
using InnoWeb.CEND.Core.Model.Blog;
using InnoWeb.CEND.Core.Model.Interfaces;
using InnoWeb.CEND.Core.Model.Reports;
using InnoWeb.CEND.Core.Model.Training;
using InnoWeb.CEND.Core.Model.Workshop;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Web.Mvc;

namespace InnoWeb.CEND.Core.Model.Expert
{
    public class ExpertInfo : BaseEntity<int>, IExpert
    {
        [Required]
        public string Name { get; set; }

        [Required]
        public string Surname { get; set; }

        public string FullName { get { return Name + " " + Surname; } set { FullName = value; } }

        [AllowHtml]
        public string ShortDescription { get; set; }

        [AllowHtml]
        public string ShortDescriptionTR { get; set; }

        [AllowHtml]
        public string Description { get; set; }

        [AllowHtml]
        public string DescriptionTR { get; set; }

        public string SchoolName { get; set; }

        [AllowHtml]
        public string ExpertiseField { get; set; }

        [AllowHtml]
        public string ExpertiseFieldTR { get; set; }

        public string ImageUrl { get; set; }

        private IList<WorkshopItem> _workshopItems;

        private IList<TrainingItem> _trainingItems;

        private IList<BlogItem> _blogItems;

        public IList<WorkshopItem> WorkshopItems
        {
            get { return _workshopItems ?? (_workshopItems = new List<WorkshopItem>()); }
            protected set { _workshopItems = value; }
        }

        public IList<TrainingItem> TrainingItems
        {
            get { return _trainingItems ?? (_trainingItems = new List<TrainingItem>()); }
            protected set { _trainingItems = value; }
        }

        public IList<BlogItem> BlogItems
        {
            get { return _blogItems ?? (_blogItems = new List<BlogItem>()); }
            protected set { _blogItems = value; }
        }


        public ExpertInfo()
        {

        }

    }
}
